package com.FQJ.stock.mapper;

import com.FQJ.stock.pojo.domain.StockBlockDomain;
import com.FQJ.stock.pojo.entity.StockBlockRtInfo;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.List;

/**
 * @Entity com.FQJ.stock.pojo.entity.StockBlockRtInfo
 */
public interface StockBlockRtInfoMapper {

    int deleteByPrimaryKey(Long id);

    int insert(StockBlockRtInfo record);

    int insertSelective(StockBlockRtInfo record);

    StockBlockRtInfo selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(StockBlockRtInfo record);

    int updateByPrimaryKey(StockBlockRtInfo record);

	/**
	 * 沪深两市板块分时行情数据查询，以交易时间和交易总金额降序查询，取前10条数据
	 * @param timePoint 指定时间点
	 * @return
	 */
	List<StockBlockDomain> sectorAllLimit(@Param("timePoint") Date timePoint);


	/**
	 * 批量插入数据
	 * @param lists
	 * @return
	 */
	int insertBath(@Param("lists") List<StockBlockRtInfo> lists);
}
